home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet internetowy / Czytniki RSS / RSS Bandit 1.3.0.42 / RssBandit Installer.msi / _172FF5180BC61D3C6D240F14338A23AA / _A97F28CE104E48078EF5B369451C53B7 < prev    next >
Text File  |  2005-04-12  |  11KB  |  247 lines

  1. <xsl:stylesheet version='1.0' 
  2.         xmlns:xsl='http://www.w3.org/1999/XSL/Transform'
  3.         xmlns:content = 'http://purl.org/rss/1.0/modules/content/'
  4.         xmlns:xhtml='http://www.w3.org/1999/xhtml'
  5.         xmlns:slash='http://purl.org/rss/1.0/modules/slash/' 
  6.         xmlns:dc='http://purl.org/dc/elements/1.1/' 
  7.         xmlns:fd='http://www.bradsoft.com/feeddemon/xmlns/1.0/'
  8.         exclude-result-prefixes='content slash dc'>
  9.  
  10.         <!-- 
  11.             Two variables, that are setup to reflect:
  12.             * AppStartupPath: the current path to the executable RssBandit.exe (C:\Program Files\RssBandit)
  13.             * AppUserDataPath: the path to the Application Data folder 
  14.             (usually C:\Documents and Settings\<username>\Application Data\RssBandit)
  15.         -->
  16. <!--        <xsl:param name='AppStartupPath'/> -->
  17.         <xsl:param name='AppUserDataPath'/>
  18.           
  19.     <xsl:variable name="AppStartupPath">file:///C:/My Download Files/</xsl:variable>    
  20.  
  21.         <xsl:output method='xml' indent='yes' /> 
  22.  
  23.  
  24.         <!-- channel group newspaper -->
  25.         <xsl:template match="newspaper[@type='group']">
  26.           <html><head><title><xsl:value-of select='title'/></title>
  27.         <!-- <base href="{//item/link}" /> -->
  28.         <!-- 
  29.         <meta http-equiv="Page-Enter" content="blendTrans(Duration=0.5)" />
  30.         <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.5)" />
  31.         -->
  32.  
  33.         <link rel="stylesheet" type="text/css" href="{$AppStartupPath}/templates/aura-8.css" />
  34.     </head>
  35.     <body>
  36.  
  37.     <table height="100%" width="100%">
  38.       <xsl:for-each select="//channel">
  39.     <tr>      
  40.         <td class="PostFrame" height="100%" width="100%" valign="top">
  41.             <xsl:if test="current()/image">
  42.                 <div class="PostTitle" style="FLOAT: right">
  43.                     <a href="{current()/image/link}" title="{current()/image/title}"><img src="{current()/image/url}"  alt="{current()/image/title}" border="0">
  44.                         <xsl:if test="current()/image/width!=''"><xsl:attribute name="width"><xsl:value-of select="current()/image/width"/></xsl:attribute></xsl:if>
  45.                         <xsl:if test="current()/image/height!=''"><xsl:attribute name="height"><xsl:value-of select="current()/image/height"/></xsl:attribute></xsl:if>
  46.                     </img></a>
  47.                 </div>
  48.             </xsl:if>
  49.             <div class="PostTitle">
  50.               <a href='{current()/link}'>            
  51.                     <xsl:value-of  disable-output-escaping='yes' select='current()/title'/>
  52.                 </a>
  53.             </div>
  54.         
  55.             <div class="PostContent">
  56.               <xsl:for-each select='current()//item'>
  57.               <div class="PostInfos">    
  58.                 <a href='{current()/link}'>
  59.                 <b><xsl:value-of disable-output-escaping="yes" select="current()/title"/></b>
  60.                 </a>
  61.               </div>
  62.                 <xsl:choose>
  63.                     <xsl:when test='current()/xhtml:body'>
  64.                         <xsl:copy-of select='current()/xhtml:body'/>
  65.                     </xsl:when>
  66.                     <xsl:when test='current()/content:encoded'>
  67.                         <xsl:value-of  disable-output-escaping='yes' select='current()/content:encoded'/>
  68.                     </xsl:when>
  69.                     <xsl:otherwise>
  70.                         <xsl:value-of disable-output-escaping='yes' select='current()/description'/>
  71.                     </xsl:otherwise>
  72.                 </xsl:choose>
  73.                     <div class="PostSignature">            
  74.                 <br />Published:
  75.                 <xsl:if test="current()/dc:creator and current()/dc:creator!=''"> 
  76.                  by <xsl:value-of disable-output-escaping='yes' select='current()/dc:creator'/>
  77.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  78.                  </xsl:if><xsl:if test="current()/author and current()/author!=''">
  79.                   <xsl:value-of disable-output-escaping='yes' select='current()/author'/>
  80.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  81.                  </xsl:if>on 
  82.             <xsl:value-of select='current()/pubDate'/>
  83.              <xsl:if test='current()/enclosure'>
  84.                 <br />
  85.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  86.                 <xsl:text disable-output-escaping='yes'><a href='</xsl:text><xsl:value-of  disable-output-escaping='yes' select='current()/enclosure/@url'/><xsl:text disable-output-escaping='yes'>'></xsl:text>
  87.                     Enclosure (<xsl:value-of select='current()/enclosure/@type'/>, <xsl:value-of select='current()/enclosure/@length'/> Bytes)
  88.                 <xsl:text disable-output-escaping='yes'></a></xsl:text>                
  89.             </xsl:if>
  90.                     
  91.             </div> 
  92.               </xsl:for-each>
  93.              </div>
  94.         
  95.         </td>
  96.     </tr>
  97.   </xsl:for-each>
  98. </table>
  99. </body></html>
  100.         </xsl:template>
  101.  
  102.         <!-- channel newspaper -->
  103.         <xsl:template match="newspaper[@type='channel']">
  104.               <html><head><title><xsl:value-of select='//channel/title'/></title>
  105.         <base href="{//channel/link}" />
  106.         <!-- 
  107.         <meta http-equiv="Page-Enter" content="blendTrans(Duration=0.5)" />
  108.         <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.5)" />
  109.         -->
  110.  
  111.         <link rel="stylesheet" type="text/css" href="{$AppStartupPath}/templates/aura-8.css" />
  112.     </head>
  113.     <body>
  114. <table height="100%" width="100%">
  115.     <tr>
  116.         <td class="PostFrame" height="100%" width="100%" valign="top">
  117.             <xsl:if test="//channel/image">
  118.                 <div class="PostTitle" style="FLOAT: right">
  119.                     <a href="{//channel/image/link}" title="{//channel/image/title}"><img src="{//channel/image/url}"  alt="{//channel/image/title}" border="0">
  120.                         <xsl:if test="//channel/image/width!=''"><xsl:attribute name="width"><xsl:value-of select="//channel/image/width"/></xsl:attribute></xsl:if>
  121.                         <xsl:if test="//channel/image/height!=''"><xsl:attribute name="height"><xsl:value-of select="//channel/image/height"/></xsl:attribute></xsl:if>
  122.                     </img></a>
  123.                 </div>
  124.             </xsl:if>
  125.             <div class="PostTitle">
  126.                 <a href='{//channel/link}'>
  127.                     <xsl:value-of  disable-output-escaping='yes' select='//channel/title'/>
  128.                 </a>
  129.             </div>
  130.         
  131.             <div class="PostContent">
  132.               <xsl:for-each select='//item'>
  133.               <div class="PostInfos">    
  134.                 <a href='{current()/link}'>
  135.                 <b><xsl:value-of disable-output-escaping="yes" select="current()/title"/></b>
  136.                 </a>
  137.               </div>
  138.                 <xsl:choose>
  139.                     <xsl:when test='current()/xhtml:body'>
  140.                         <xsl:copy-of select='current()/xhtml:body'/>
  141.                     </xsl:when>
  142.                     <xsl:when test='current()/content:encoded'>
  143.                         <xsl:value-of  disable-output-escaping='yes' select='current()/content:encoded'/>
  144.                     </xsl:when>
  145.                     <xsl:otherwise>
  146.                         <xsl:value-of disable-output-escaping='yes' select='current()/description'/>
  147.                     </xsl:otherwise>
  148.                 </xsl:choose>
  149.                     <div class="PostSignature">            
  150.                 <br />Published:
  151.                 <xsl:if test="current()/dc:creator and current()/dc:creator!=''"> 
  152.                  by <xsl:value-of disable-output-escaping='yes' select='current()/dc:creator'/>
  153.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  154.                  </xsl:if><xsl:if test="current()/author and current()/author!=''">
  155.                   <xsl:value-of disable-output-escaping='yes' select='current()/author'/>
  156.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  157.                  </xsl:if>on 
  158.             <xsl:value-of select='current()/pubDate'/>
  159.              <xsl:if test='current()/enclosure'>
  160.                 <br />
  161.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  162.                 <xsl:text disable-output-escaping='yes'><a href='</xsl:text><xsl:value-of  disable-output-escaping='yes' select='current()/enclosure/@url'/><xsl:text disable-output-escaping='yes'>'></xsl:text>
  163.                     Enclosure (<xsl:value-of select='current()/enclosure/@type'/>, <xsl:value-of select='current()/enclosure/@length'/> Bytes)
  164.                 <xsl:text disable-output-escaping='yes'></a></xsl:text>                
  165.             </xsl:if>
  166.                     
  167.             </div> 
  168.               </xsl:for-each>
  169.              </div>
  170.         
  171.         </td>
  172.     </tr>
  173. </table>
  174. </body></html>
  175.         </xsl:template>
  176.  
  177.         
  178.  
  179.         <!-- single news item -->
  180.         <xsl:template match="newspaper[@type='newsitem']">
  181.         <html><head><title><xsl:value-of select='//item/title'/></title>
  182.         <base href="{//item/link}" />
  183.         <!-- 
  184.         <meta http-equiv="Page-Enter" content="blendTrans(Duration=0.5)" />
  185.         <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.5)" />
  186.         -->
  187.  
  188.         <link rel="stylesheet" type="text/css" href="{$AppStartupPath}/templates/aura-8.css" />
  189.     </head>
  190.     <body>
  191. <table height="100%" width="100%">
  192.     <tr>
  193.         <td class="PostFrame" height="100%" width="100%" valign="top">
  194.             <xsl:if test="//channel/image">
  195.                 <div class="PostTitle" style="FLOAT: right">
  196.                     <a href="{//channel/image/link}" title="{//channel/image/title}"><img src="{//channel/image/url}"  alt="{//channel/image/title}" border="0">
  197.                         <xsl:if test="//channel/image/width!=''"><xsl:attribute name="width"><xsl:value-of select="//channel/image/width"/></xsl:attribute></xsl:if>
  198.                         <xsl:if test="//channel/image/height!=''"><xsl:attribute name="height"><xsl:value-of select="//channel/image/height"/></xsl:attribute></xsl:if>
  199.                     </img></a>
  200.                 </div>
  201.             </xsl:if>
  202.             <div class="PostTitle">
  203.                 <a href='{//item/link}'>
  204.                     <xsl:value-of  disable-output-escaping='yes' select='//item/title'/>
  205.                 </a>
  206.             </div>
  207.             <div class="PostInfos">
  208.                 <b><xsl:value-of select="//item/category"/></b>
  209.             </div>
  210.             <div class="PostContent">
  211.                 <xsl:choose>
  212.                     <xsl:when test='//item/xhtml:body'>
  213.                         <xsl:copy-of select='//item/xhtml:body'/>
  214.                     </xsl:when>
  215.                     <xsl:when test='//item/content:encoded'>
  216.                         <xsl:value-of  disable-output-escaping='yes' select='//item/content:encoded'/>
  217.                     </xsl:when>
  218.                     <xsl:otherwise>
  219.                         <xsl:value-of disable-output-escaping='yes' select='//item/description'/>
  220.                     </xsl:otherwise>
  221.                 </xsl:choose>
  222.              </div>
  223.             <div class="PostSignature">
  224.                 <a href='{//channel/link}' title='{//channel/description}'><xsl:value-of disable-output-escaping='yes'  select='//channel/title'/></a>
  225.                 <br />Published:
  226.                 <xsl:if test="//item/dc:creator and //item/dc:creator!=''">
  227.                 <xsl:value-of disable-output-escaping='yes' select='//item/dc:creator'/>
  228.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  229.                  </xsl:if><xsl:if test="//item/author and //item/author!=''">
  230.                   <xsl:value-of disable-output-escaping='yes' select='//item/author'/>
  231.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  232.                  </xsl:if>
  233.             <xsl:value-of select='//item/pubDate'/>
  234.              <xsl:if test='//item/enclosure'>
  235.                 <br />
  236.                 <xsl:text disable-output-escaping='yes'>&nbsp;</xsl:text>
  237.                 <xsl:text disable-output-escaping='yes'><a href='</xsl:text><xsl:value-of  disable-output-escaping='yes' select='//item/enclosure/@url'/><xsl:text disable-output-escaping='yes'>'></xsl:text>
  238.                     Enclosure (<xsl:value-of select='//item/enclosure/@type'/>, <xsl:value-of select='//item/enclosure/@length'/> Bytes)
  239.                 <xsl:text disable-output-escaping='yes'></a></xsl:text>                
  240.             </xsl:if>            
  241.             </div>
  242.         </td>
  243.     </tr>
  244. </table>
  245. </body></html>
  246. </xsl:template>
  247. </xsl:stylesheet>